package com.lhkj.ct.meta.modules.gauge.service;

import com.lhkj.ct.base.mybatis.extension.service.BatchHandleService;
import com.lhkj.ct.meta.modules.gauge.common.enums.GaugeType;
import com.lhkj.ct.meta.modules.gauge.model.dto.QuestionsDto;
import com.lhkj.ct.meta.modules.gauge.model.entity.TblGaugeQuestion;

import java.util.List;

/**
 * <p>
 * 服务类
 * </p>
 *
 * @author jobob
 * @since 2023-10-08
 */
public interface GaugeQuestionService extends BatchHandleService<TblGaugeQuestion> {

    /**
     * 查询量表/问卷题目和选项和逻辑
     * @param gaugeId
     * @param type
     * @return
     */
    List<TblGaugeQuestion> selectQutWithOptWithLogicByGaugeId(String gaugeId, GaugeType type);

    /**
     * 查询量表/问卷题目
     * @param gaugeId
     * @param type
     * @return
     */
    List<TblGaugeQuestion> selectQutByGaugeId(String gaugeId, GaugeType type);

    /**
     * 批量保存题目
     * @param gaugeId       量表、问卷id
     * @param type          测量类型 1.量表 2.问卷
     */
    void saveByGauge(String gaugeId, GaugeType type, QuestionsDto questionsDto);

}
